<?php

//防止恶意调用
if (!defined('IN_MOD'))
{
    die('Hacking attempt');
}

if($configname == "list")
{
	$module_block = "list";	
}

if($configname == "detail")
{
	$module_block = "detail";	
}

// 前台模板配置后台模板功能[NEW]
$admintplconfig = getadmintplconfig($configinfo['moduleid']);
if(in_array($module_block,$admintplconfig))
{
	if($configinfo['modulename'])
	{
		if(iffile(MODULEPARA_PATH."config/admin/".$configinfo['modulename']."/"))
		{
			$this->view->engine->config('view_base', MODULEPARA_PATH."config/admin/".$configinfo['modulename']."/");
		}
		
		// 加载模板程序配置
		if($configinfo['tplok'] == 1)
		{
			if(iffile($configinfo['tplurl']."config/admin/".$configinfo['modulename']."/"))
			{
				$this->view->engine->config('view_base', $configinfo['tplurl']."config/admin/".$configinfo['modulename']."/");
			}
		}
	}
}
?>